<template>
    <div>
        <h1>和差问题1</h1>
        <el-form label-width="100px">
            <el-form-item label="甲：">
                <el-slider v-model="v1"  show-input></el-slider>
            </el-form-item>
            <el-form-item label="乙：">
                <el-slider v-model="v2"  show-input></el-slider>
            </el-form-item>
            <el-form-item label="两数之和：">
                {{v1 + v2}}
            </el-form-item>
            <el-form-item label="两数之差：">
                {{Math.abs(v1 - v2)}}
            </el-form-item>
        </el-form>
        <div style="padding:10px 10px">
        </div>

    </div>
</template>

<script>
    export default {
        name: "sum_diff.vue",
        data() {
            return {
                v1: 30,
                v2: 50,
            }
        },
    }
</script>

<style scoped>

</style>
